
PROJECT(ExtIProf)

IF (WIN32)
  #INCLUDE_DIRECTORIES(${EDUNET_GAMES_SOURCE_DIR}/Glut)
ELSE (WIN32)
  INCLUDE_DIRECTORIES(${GLUT_INCLUDE_DIR})
ENDIF (WIN32)

SET(IPROF_SOURCES
prof_draw.c
prof_gather.c
prof_process.c
)


SET(IPROF_HEADERS
prof.h
prof_gather.h
prof_internal.h
)

IF (WIN32)
	SET(IPROF_PLATTFORM_SOURCES
	prof_win32.c
	)

	SET(IPROF_PLATTFORM_HEADERS
	prof_win32.h
	)
ELSE (WIN32)
	SET(IPROF_PLATTFORM_SOURCES
	prof_unix.c
	)

	SET(IPROF_PLATTFORM_HEADERS
	prof_unix.h
	)
ENDIF (WIN32)

IF (NOT WIN32)
   SET(CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
ENDIF (NOT WIN32)

ADD_LIBRARY(${PROJECT_NAME} STATIC ${IPROF_SOURCES}  ${IPROF_PLATTFORM_SOURCES})
set_property( TARGET ${PROJECT_NAME} PROPERTY FOLDER "edunet/external/libraries" )

set_target_properties( ${PROJECT_NAME} PROPERTIES
	ARCHIVE_OUTPUT_DIRECTORY ${EDUNET_COMMON_LIB_OUTPUT_DIRECTORY} )

set_target_properties( ${PROJECT_NAME} PROPERTIES DEBUG_POSTFIX "_Debug" )
set_target_properties( ${PROJECT_NAME} PROPERTIES RELEASE_POSTFIX "_Release" )
set_target_properties( ${PROJECT_NAME} PROPERTIES MINSIZEREL_POSTFIX "_MinsizeRel" )
set_target_properties( ${PROJECT_NAME} PROPERTIES RELWITHDEBINFO_POSTFIX "_RelWithDebugInfo" )
	